#ifndef __Key_H
#define __Key_H

#ifdef APM32E10X_HD
	#include "apm32e10x_gpio.h"
	#include "apm32e10x_rcm.h"
	#include "apm32e10x_eint.h"
	#include "apm32e10x_misc.h"
	
#elif defined AT32F403AVGT7
	#include "at32f403a_407_gpio.h"
	#include "at32f403a_407_crm.h"
	#include "at32f403a_407_exint.h"
	#include "at32f403a_407_misc.h"

#else
	#include "apm32f10x_gpio.h"
	#include "apm32f10x_rcm.h"
	#include "apm32f10x_eint.h"
	#include "apm32f10x_misc.h"

#endif
#include "BoardData.h"

#ifdef SQDri_EVSEB_7KW
//引脚块1 = PE15
#define Key_RTC             RCM_APB2_PERIPH_GPIOE
#define Key_PinPort         GPIOE
#define Key1_PinId          GPIO_PIN_15   //切换充电按键

#elif defined SQDri_EVSEB_11KW
//引脚块1 = 接引脚块B = PE15
#define Key_RTC             RCM_APB2_PERIPH_GPIOE
#define Key_PinPort         GPIOE
#define Key1_PinId          GPIO_PIN_15   //切换充电按键

#elif key1_Ctrl_id == KeyCtrl_UpBoard
#define Key_RTC             RCM_APB2_PERIPH_GPIOB
#define Key_PinPort         GPIOB
#define Key1_PinId          GPIO_PIN_12   //切换充电按键

#else

#include "LedPanel.h"
//引脚块1 = 接引脚块B = PB5
#define Key_RTC             Led1_RTC
#define Key_PinPort         Led1_PinPort
#define Key1_PinId          Led1_5PinId                  //切换充电按键

#endif


void key_init(void);
uint8_t key_get_level(void);

#endif



